package com.handle.kafka;

import org.apache.kafka.clients.consumer.ConsumerRecord;
import org.springframework.kafka.annotation.KafkaListener;
import org.springframework.stereotype.Component;

/**
 * @author: create by God of SJF
 * @version: v1.0
 * @description: com.handle.kafka
 * @date:2021/8/27
 */
@Component
public class Customer {

    @KafkaListener(topics = "libin")
    public void listen(ConsumerRecord<?, ?> record){
        System.out.println("简单消费："+record.topic()+"-"+record.partition()+"-"+record.value());

    }
}
